Skip to content
AllenYGY's Blog
Search
K
Main Navigation
Home
Blog
Tags
Archive
Note
Functional Programming
Theory Of Computation
Compiler Construction
Computer Graphics
Computer Network
Database Management System
Computer Organization
Operating System
Appearance
Menu
Return to top
On this page
Navie Bayes
Bayesian Classification
Let the dataset
T
be:
T
=
{
(
x
1
,
y
1
)
,
(
x
2
,
y
2
)
,
…
,
(
x
N
,
y
N
)
}
Each input
x
i
is represented as:
x
i
=
(
x
1
,
…
,
x
n
)
Each output
y
i
belongs to a class
c
k
, where
k
=
1
,
…
,
K
.
The probability of a class
c
k
given input
x
is calculated as:
P
(
y
=
c
k
∣
x
)
=
P
(
y
=
c
k
)
P
(
x
∣
y
=
c
k
)
∑
k
P
(
y
=
c
k
)
P
(
x
∣
y
=
c
k
)
P
(
y
=
c
k
|
x
)
∝
P
(
y
=
c
k
)
P
(
x
|
y
=
c
k
)
P
(
y
=
c
k
|
x
)
∝
P
(
y
=
c
k
)
∏
j
P
(
x
j
|
y
=
c
k
)